PROJ   = ../../bin/id
OBJS   = $(patsubst %.cpp, %.o, $(wildcard ../common/*.cpp *.cpp))
CC     = g++
LINK   = g++
RM     = rm -rf
CFLAGS = -c -Wall \
         -I/usr/include/acl-lib/acl_cpp \
         `mysql_config --cflags` \
         -I../common \
		 -g -F dwarf
LIBS   = -pthread -lacl_all `mysql_config --libs`
 
all: $(PROJ)

$(PROJ): $(OBJS)
	$(LINK) $^ $(LIBS) -o $@

.cpp.o:
	$(CC) $(CFLAGS) $^ -o $@

clean:
	$(RM) $(PROJ) $(OBJS)